<html lang="en" xmlns:th="http://www.thymeleaf.org">
<div th:fragment="addAndEditDiv" style="display: none" id="addAndEditId">
    <form class="layui-form" action="" id="addAndEditForm">
        <input type="hidden" name="id" id="id">
        <div class="layui-form-item">
            <label class="layui-form-label">小区名称</label>
            <div class="layui-input-inline">
                <input type="text" name="name" lay-verify="required" placeholder="请输入小区名称" autocomplete="off"
                       class="layui-input" lay-reqtext="小区名称是必填项，岂能为空？">
            </div>
            <label class="layui-form-label">小区编码</label>
            <div class="layui-input-inline">
                <input type="text" name="code" lay-verify="required" placeholder="请输入小区编码" autocomplete="off"
                       class="layui-input" lay-reqtext="小区编码是必填项，岂能为空？">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label" style="width: 100px">小区所属省份</label>
            <div class="layui-input-inline">
                <select name="parentAreaCode" lay-filter="prov">
                    <option value="">请选择所在省份</option>
                    <option th:each="prov : ${provList}" th:value="${prov.getAreaCode()}" th:text="${prov.getAreaName()}"></option>
                </select>
            </div>
            <label class="layui-form-label">小区所属市</label>
            <div class="layui-input-inline">
                <select name="areaCode">
                    <option value="">请选择所在市</option>
                </select>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">详细地址</label>
            <div class="layui-input-block">
                <input type="text" name="address" lay-verify="required" placeholder="请输入小区详细地址" autocomplete="off"
                       class="layui-input" lay-reqtext="小区详细地址是必填项，岂能为空？">
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <button type="submit" class="layui-btn" lay-submit="" lay-filter="subBtn">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
    </form>
</div>
</html>